package com.yeyks.commonReference.service.mattress;

import com.baomidou.mybatisplus.extension.service.IService;
import com.yeyks.account.dal.domain.AccountInfo;
import com.yeyks.common.ajax.AjaxResponseBody;
import com.yeyks.common.base.PageResult;
import com.yeyks.common.param.OrderInfoMattressParam;
import com.yeyks.common.result.OrderInfoMattressResult;
import com.yeyks.mattress.dal.domain.OrderInfoMattress;
import com.yeyks.mattress.param.CheckMattressStartSuccessParam;
import com.yeyks.mattress.param.OrderInfoMattressOrderListParam;
import com.yeyks.mattress.param.OrderInfoMattressOrderPayFailParam;
import com.yeyks.mattress.param.OrderInfoMattressPlaceAnOrderParam;
import com.yeyks.mattress.vo.CheckMattressStartSuccessVo;
import com.yeyks.mattress.vo.OrderInfoMattressOrderListVo;
import com.yeyks.mattress.vo.OrderInfoMattressOrderPayFailVo;
import com.yeyks.mattress.vo.OrderInfoMattressPlaceAnOrderVo;
import org.springframework.validation.annotation.Validated;


/**
 * <p>
 * 共享床垫订单表 服务类
 * </p>
 *
 * @author yun
 * @since 2019-07-16
 */
public interface OrderInfoMattressService extends IService<OrderInfoMattress> {

    /**
     * 订单信息:v3.3.a
     *
     * @param param
     * @return
     */
    OrderInfoMattressOrderListVo orderList(@Validated OrderInfoMattressOrderListParam param);

    /**
     * 下单:v3.3.a
     *
     * @param param
     * @return
     */
    OrderInfoMattressPlaceAnOrderVo placeAnOrder(OrderInfoMattressPlaceAnOrderParam param);

    /**
     * 订单支付失败:v3.3.a
     *
     * @param param
     * @return
     */
    OrderInfoMattressOrderPayFailVo orderPayFail(OrderInfoMattressOrderPayFailParam param);

    /**
     * 订单列表
     *
     * @param param
     * @return
     */
    PageResult<OrderInfoMattressResult> myList(OrderInfoMattressParam param, AccountInfo loginUser);

    /**
     * 共享床垫退款
     *
     * @param orderNo   订单号
     * @param loginUser 当前操作人
     * @return
     */
    Boolean refund(String orderNo, AccountInfo loginUser);

    /**
     * 查询床垫是否启动成功:v1.0.1
     *
     * @param param
     * @return
     */
    CheckMattressStartSuccessVo checkMattressStartSuccess(@Validated CheckMattressStartSuccessParam param);

}
